package di.component;

import javax.inject.Singleton;

import app.OkApplication;
import dagger.BindsInstance;
import dagger.Component;
import dagger.android.support.AndroidSupportInjectionModule;
import di.module.ActivityModule;
import di.module.AppModule;
import di.module.NetWorkModule;
import di.module.ViewModelModule;

@Singleton
@Component(modules = {
        AndroidSupportInjectionModule.class,
        ActivityModule.class,
        ViewModelModule.class,
        AppModule.class,
        NetWorkModule.class
        })
public interface AppComponent {
    void inject(OkApplication application);

    @Component.Builder
    interface Builder {

        AppComponent build();

        @BindsInstance
        Builder application(OkApplication application);
    }
}
